<?php
namespace app\admin\validate\Meta;
use yzh52521\validate\Validate;

class RoleValidate extends validate{

	/**
	 *@description 验证器规则
	 *@buildcode(true)
	*/
	protected $rule = [
		'name'=>['require'],
		'model_ids'=>['require'],
		'action_ids'=>['require'],
	];

	/**
	 *@description 错误提示
	 *@buildcode(true)
	*/
	protected $message = [
		'name.require'=>'名字不能为空',
		'model_ids.require'=>'模型不能为空',
		'action_ids.require'=>'动作不能为空',
	];

	/**
	 *@description 验证场景
	 *@buildcode(true)
	*/
	protected $scene  = [
		'add'=>['name','model_ids','action_ids'],
		'update'=>['name','model_ids','action_ids'],
	];



}